]> dgit.raspbian.org Git - gnome-shell.git/commit
st/theme-context: Also invalidate root node on stylesheet changes
authorJonas Dreßler <verdre@v0yd.nl>
Mon, 6 Apr 2020 00:11:27 +0000 (02:11 +0200)
committerCarlos Garnacho <mrgarnacho@gmail.com>
Mon, 6 Apr 2020 10:45:55 +0000 (10:45 +0000)
commitbc973b80d77ba36e29fbeba27a2bed9e2ea6cf09
treed2eb527cc14740ad84c5717000059afed0f7360b
parent85846d88f034a605f6cb0aa013f2ab80e2f760bd
st/theme-context: Also invalidate root node on stylesheet changes

Since commit 6a42d7726119c538d260e54cdbe2f31e5fbeb03c we invalidate the
cached properties for each theme node on stylesheet changes by iterating
over the hashtable of the theme context instead of listening to the
signal in each individual theme node.

That commit forgot one particular node though that's not stored in the
hashtable, but using the `priv->root_node` property instead: The theme
node that belongs to the stage.

So make sure we also invalidate the cached properties of the stage theme
node on stylesheet changes. This fixes various crashes that happened
with extensions providing custom stylesheets (emitting the
"custom-stylesheets-changed" signal on every extension enable/disable),
trying to access an already freed CSS property of the stage.

Fixes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2584
src/st/st-theme-context.c